package com.freedom.admin.application.converter;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.freedom.admin.infrastructure.persistence.pojo.bo.UserAuthBO;
import com.freedom.admin.infrastructure.persistence.pojo.bo.UserBO;
import com.freedom.admin.infrastructure.persistence.pojo.bo.UserFormBO;
import com.freedom.admin.infrastructure.persistence.pojo.form.UserForm;
import com.freedom.admin.infrastructure.persistence.pojo.vo.user.LoginUserVO;
import com.freedom.admin.infrastructure.persistence.pojo.vo.user.UserVO;
import com.freedom.admin.api.pojo.dto.UserAuthDTO;
import org.mapstruct.Mapper;

@Mapper(componentModel = "spring")
public interface UserConverter {
    Page<UserVO> toPageVO(Page<UserBO> userBOPage);

    UserForm poToForm(UserFormBO userFormBO);

    UserBO formToBO(UserForm userForm);

    UserAuthDTO toUserAuthDTO(UserAuthBO userAuthBO);

    LoginUserVO toLoginUserVO(UserBO userBO);
}
